<?php

namespace app\admin\validate;
use think\Validate;

class Essay extends Validate
{
    protected $rule = [
        'title'   		=> 'require',
        'picture' 		=> 'require',
        'link'   		=> 'require',
        'integral'   	=> 'float',
        'link'   		=> 'url',
    ];

    protected $message = [
        'title.require'   	=> '文章名称不能为空',
        'picture.require' 	=> '缩略图不能为空',
        'link.require'   	=> '链接地址不能为空',
        'integral.float'  	=> '赠送积分只能为数字',
        'link.url'  		=> '链接地址不合法',
    ];
}
